﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Home.master" AutoEventWireup="true" CodeFile="GioHang.aspx.cs" Inherits="GioHang" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <div class="container">
        <div class="col-xs-12 col-md-12">
            <div class="row">
                <div class="col-md-12">
                    <ul class="breadcrumb">
                        <li><a href="#"><span class="glyphicon glyphicon-home"></span></a></li>
                        <li><a href="#">Giỏ Hàng</a></li>
                    </ul>
                </div>
            </div>
            <div class="row">
                <div class="col-md-12">
                    <asp:Panel ID="Panel1" runat="server" Height="59px">
                        <asp:Label ID="lblthongbao" runat="server" Style="color: #FF0000"
                            Text="Hiện tại chưa có sản phẩm nào trong giỏ hàng của bạn"></asp:Label>
                        <br />
                        <asp:HyperLink ID="hpkChonhang" runat="server" NavigateUrl="~/Default.aspx">Về trang chủ để chọn hàng</asp:HyperLink>
                    </asp:Panel>
                    <asp:Panel ID="Panel2" runat="server">

                        <asp:GridView ID="gridGiohang" runat="server" AllowPaging="True"
                            AutoGenerateColumns="False"
                            OnPageIndexChanging="gridGiohang_PageIndexChanging" OnRowDeleting="gridGiohang_RowDeleting"
                            Width="100%" OnRowUpdating="gridGiohang_RowUpdating">
                            <Columns>
                                <asp:TemplateField HeaderText="Hình Ảnh">
                                    <ItemTemplate>

                                        <asp:Image ID="Image2" runat="server" CssClass="news-img"
                                            ImageUrl='<%# "~/"+Eval("Hinhanh") %>'
                                            ToolTip='<%# Eval("TenSP") %>' />
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="Sản Phẩm">
                                    <ItemTemplate>
                                        <asp:HyperLink ID="HyperLink4" runat="server" CssClass="cart-color"
                                            NavigateUrl='<%# Eval("MaSP", "../Product-Detail.aspx?masp={0}") %>'
                                            Text='<%# Eval("TenSP") %>'></asp:HyperLink>
                                        <asp:Label ID="lblMaSP" runat="server" Text='<%# Bind("masp") %>'
                                            Visible="False"></asp:Label>

                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="Số lượng">
                                    <ItemTemplate>
                                        <asp:TextBox ID="txtSoluong" runat="server" CssClass="input-sl" Text='<%# Bind("soluong") %>'></asp:TextBox>
<%--                                        <asp:Button ID="btnSuaSL" runat="server" Text="Sửa" CssClass="btn btn-info btn-xs" />
                                        <asp:Button ID="btnXoaSL" runat="server" Text="Xóa" CssClass="btn btn-danger btn-xs" />  --%>                        
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="Giá bán">
                                    <ItemTemplate>
                                        <asp:Label ID="lblDonGia" runat="server" CssClass="cart-color" Text='<%#Eval("Gia","{0:0,00} ₫")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="Tổng">
                                    <ItemTemplate>
                                        <asp:Label ID="lblTongtien" runat="server" Font-Bold="True" CssClass="cart-color"
                                            Text='<%# Bind("tonggia") %>'></asp:Label>
                                        <br />
                                    </ItemTemplate>
                                </asp:TemplateField>

                            </Columns>
                        </asp:GridView>
                                            <hr />
                                         <p class="pull-right">
                           Tổng cộng:	  <asp:Label ID="lblTongtien" runat="server" Text="[Chưa Có]" CssClass="cart-color"></asp:Label></p>
                    </asp:Panel>

                </div>
            </div>
        </div>
    </div>
</asp:Content>

